	frames reset 
	// PyTwoway results 
		use "${output}/twfe/geo_twfe/physicians/geotwfe03-FEestimates_physicians.dta", clear
		g sample = "physicians"
		append using "${output}/twfe/geo_twfe/lawyers/geotwfe03-FEestimates_lawyers.dta"
		replace sample = "lawyers" if sample == ""
		append using "${output}/twfe/firm_twfe/firmtwfe03-FEestimates_physicians.dta"
		replace sample = "firm-twfe (physicians)" if sample == ""
		ren n_workers N_UR
		
		reshape long @__fe @__ho @__he, i(sample) j(effect) string 
		foreach i in fe ho he { 
			g sh_var_`i' = __`i' / var_y_	
		}
		
		ds sample effect N_UR, not
		drbest_docinc `r(varlist)' 
		drbcount N_UR, gen(N)
		order N_UR, last
		export delimited using "$mypath/intermediate_csv/twfe01-earnings_decompositions_pytwoway.csv", replace dataf delim(tab)  	
		
	// Card et al (2013)
	frame create card
		# d ;
		loc files
			geo_twfe/geotwfe06-earnings_decomp_card_nocontrols
			geo_twfe/physicians/geotwfe04-earnings_decomp_card_controls_physicians
			geo_twfe/lawyers/geotwfe04-earnings_decomp_card_controls_lawyers
			firm_twfe/earnings_decomp_card_controls_physicians_EINsize15
			firm_twfe/earnings_decomp_card_nocontrols_physicians_EINsize15
		;
		# d cr
		
		loc i = 1
		foreach file of loc files {
			use "${output}/twfe/`file'.dta", clear
			g filename = "`file'"
			tempfile temp`i'
			save `temp`i''
			frame card: append using `temp`i''
			loc ++i
		}
		
		frame change card
		
		replace sample = "firm-twfe (physicians)" if regexm(filename, "firm_twfe")
		replace sample = "lawyers" if regexm(filename, "lawyers")
		
		ds sample spec effect filename N_UR, not
		drbest_docinc `r(varlist)' 
		drbcount N_UR, gen(N)
		export delimited using "$mypath/intermediate_csv/twfe01-earnings_decompositions.csv", replace dataf delim(tab)
